<template>
	<view>
		<noneData noneTitle="暂无数据~" v-if="listData.length === 0"></noneData>
		<view class="list_wrapper" v-for="item in listData" :key="item.id">
			<view class="p_font_32">{{item.question}}</view>
			<view class="p_font_28 p_color_7a p_margin_t_16">{{item.answer}}</view>
		</view>
	</view>
</template>

<script>
	import noneData from '../../components/noneData.vue';

	export default {
		components: {
			noneData
		},
		data() {
			return {
				listData: [],
			}
		},
		onLoad() {
			this.getListData();
		},
		methods: {
			getListData() {
				this.$http.post(this.$api.question).then(res => {
					this.listData = res.data;
				})
			}
		}
	}
</script>

<style lang="less">
	.list_wrapper {
		padding: 32rpx;
	}
</style>
